YNQ  YNQ-1.6.0
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups
Search Operations

Data Structures

struct  CCFindFileDataA
 
struct  CCFindFileData
 

Typedefs

typedef struct CCFindFileDataA FindFileDataA_t
 

Functions

NQ_HANDLE ccFindFirstFileA (const NQ_CHAR *srchPath, FindFileDataA_t *findFileData, NQ_BOOL extractFirst)
 
NQ_HANDLE ccFindFirstFile (const NQ_WCHAR *srchPath, CCFindFileData *findFileData, NQ_BOOL extractFirst)
 
NQ_BOOL ccFindNextFileA (NQ_HANDLE handle, FindFileDataA_t *findFileData)
 
NQ_BOOL ccFindNextFile (NQ_HANDLE handle, CCFindFileData *findFileData)
 
NQ_BOOL ccFindClose (NQ_HANDLE handle)
 

Detailed Description

Typedef Documentation

This structure is used when calling ccFindFirstFile() and ccFindNextFile() calls.

Function Documentation

NQ_HANDLE ccFindFirstFileA ( const NQ_CHAR srchPath,
FindFileDataA_t findFileData,
NQ_BOOL  extractFirst 
)

This function is called by application to find a first file matching the specified search criteria. On success, this function returns a search handle which can be used by application for getting more search results (ccFindNextFile()). At the end of the search the application should close this handle by calling ccFindClose().

The srchPath argument (see below) designates either a local or a remote path. A remote path starts with a mount point name. Any other path, which does not start from a mount point is considered local. A local path, regardless of its form, designates a list of mount points.

Parameters
srchPathPath and the filename to search on the remote share. Wildcard characters are applicable for the filename.
findFileDataPointer to a structure, where NQ places the search result data in CCFindFileData structure.
extractFirstThis flag specifies whether NQ should place the search results data for this call (if TRUE), or it should only open the search handle for the specified path for future search data retrieval (if FALSE) by calling ccFindNextFile().
Returns
This function returns NULL if it cannot create a handle or a valid handle otherwise. The application can inspect the error code for the failure reason. Error code NQ_ERR_OK means that there are no files on a remote share matching the search criteria CCFindFileData structure
See Also
ccFindNextFile() ccFindClose()
Note
  • When application calls this function with a local path, NQ Client will lock the list of mount points until the ccFindClose() will be called. During that period any other application thread trying to call a function from NQ Client API may remain locked.
  • This is an ASCII version of ccFindFirstFile()
NQ_HANDLE ccFindFirstFile ( const NQ_WCHAR srchPath,
CCFindFileData findFileData,
NQ_BOOL  extractFirst 
)

This function is called by application to find a first file matching the specified search criteria. On success, this function returns a search handle which can be used by application for getting more search results (ccFindNextFile()). At the end of the search the application should close this handle by calling ccFindClose().

The srchPath argument (see below) designates either a local or a remote path. A remote path starts with a mount point name. Any other path, which does not start from a mount point is considered local. Specifying a mount point name for example '\mnt' or '\*' or '\*.*' will return a list of mount points currently mounted.

Parameters
srchPathPath and the filename to search on the remote share. Wildcard characters are applicable for the filename.
findFileDataPointer to a structure, where NQ places the search result data in CCFindFileData structure.
extractFirstThis flag specifies whether NQ should place the search results data for this call (if TRUE), or it should only open the search handle for the specified path for future search data retrieval (if FALSE) by calling ccFindNextFile().
Returns
This function returns NULL if it cannot create a handle or a valid handle otherwise. The application can inspect the error code for the failure reason. Error code NQ_ERR_OK means that there are no files on a remote share matching the search criteria.
See Also

CCFindFileData structure ccFindNextFile() ccFindClose()

Note
When application calls this function with a local path, NQ Client will lock the list of mount points until the ccFindClose() will be called. During that period any other application thread trying to call a function from NQ Client API may remain locked.
NQ_BOOL ccFindNextFileA ( NQ_HANDLE  handle,
FindFileDataA_t findFileData 
)

This function is called by application to find a next file matching the specified wildcard.

Parameters
handleHandle value returned by calling ccFindFirstFile().
findFileDataPointer to a structure, where NQ places the search result data in CCFindFileData structure.
Returns
This function returns TRUE if the next file was found successfully or FALSE otherwise. The application can inspect the error code for the failure reason. Error code NQ_ERR_OK means that there are no more files on a remote share matching the search criteria.
See Also

CCFindFileData structure ccFindFirstFile() ccFindClose()

Note
This is an ASCII version of ccFindNextFile()
NQ_BOOL ccFindNextFile ( NQ_HANDLE  handle,
CCFindFileData findFileData 
)

This function is called by application to find a next file matching the specified wildcard.

Parameters
handleHandle value returned by calling ccFindFirstFile().
findFileDataPointer to a structure, where NQ places the search result data in CCFindFileData structure.
Returns
This function returns TRUE if the next file was found successfully or FALSE otherwise. The application can inspect the error code for the failure reason. Error code NQ_ERR_OK means that there are no more files on a remote share matching the search criteria.
See Also
CCFindFileData structure ccFindFirstFile() ccFindClose()
NQ_BOOL ccFindClose ( NQ_HANDLE  handle)

This function is called by application to close the search handle

Parameters
handleHandle value returned by calling the ccFindFirstFile()
Returns
This function returns TRUE if the search handle is closed successfully or FALSE otherwise. The application can inspect the error code for the failure reason.